package com.mrd.gtimpframe.entity;

import java.io.Serializable;

public class BizProtocolConfirmRefKey implements Serializable {
    private String protocolId;

    private String confirmId;

    private static final long serialVersionUID = 1L;

    public BizProtocolConfirmRefKey(String protocolId, String confirmId) {
        this.protocolId = protocolId;
        this.confirmId = confirmId;
    }

    public BizProtocolConfirmRefKey() {
        super();
    }

    public String getProtocolId() {
        return protocolId;
    }

    public void setProtocolId(String protocolId) {
        this.protocolId = protocolId == null ? null : protocolId.trim();
    }

    public String getConfirmId() {
        return confirmId;
    }

    public void setConfirmId(String confirmId) {
        this.confirmId = confirmId == null ? null : confirmId.trim();
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", protocolId=").append(protocolId);
        sb.append(", confirmId=").append(confirmId);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        BizProtocolConfirmRefKey other = (BizProtocolConfirmRefKey) that;
        return (this.getProtocolId() == null ? other.getProtocolId() == null : this.getProtocolId().equals(other.getProtocolId()))
            && (this.getConfirmId() == null ? other.getConfirmId() == null : this.getConfirmId().equals(other.getConfirmId()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getProtocolId() == null) ? 0 : getProtocolId().hashCode());
        result = prime * result + ((getConfirmId() == null) ? 0 : getConfirmId().hashCode());
        return result;
    }
}